﻿using Sc.Domain;
using Sc.Persistence;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sc.Service
{
    public class TrainDetailService
    {
        private readonly TrainDetailDAO dal = new TrainDetailDAO();

		#region  BasicMethod
		/// <summary>
		/// 增加一条数据
		/// </summary>
		public int  Add(TrainDetail model)
		{
			return dal.Add(model);
		}

		/// <summary>
		/// 更新一条数据
		/// </summary>
		public bool Update(TrainDetail model)
		{
			return dal.Update(model);
		}

		/// <summary>
		/// 删除一条数据
		/// </summary>
		public bool Delete(int Id)
		{
			return dal.Delete(Id);
		}
		/// <summary>
		/// 删除一条数据
		/// </summary>
		public bool DeleteList(string Idlist )
		{
			return dal.DeleteList(Idlist );
		}
        /// <summary>
        /// 获取明细信息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public IList<TrainDetail> GetList(int id)
        {
            return this.dal.GetList(id);
        }
		#endregion  BasicMethod
    }
}
